package ooboo;

import java.text.DateFormat;
import java.text.SimpleDateFormat;
import java.util.Date;

public class StoredTweet
{
	private static final DateFormat dateFormat = new SimpleDateFormat("MMM d h:mma");
	
	private long id;
	private Date createdAt;
	private String text;
	private String source;
	private String screenName;
	private String dateString;
	
	public StoredTweet(long id,Date createdAt,String text,String source,String screenName)
	{
		this.id = id;
		this.createdAt = createdAt;
		this.text = text;
		this.source = "from " + source;
		this.screenName = screenName;
		dateString = dateFormat.format(createdAt);
	}

	public Date getCreatedAt()
	{
		return createdAt;
	}
	
	public long getId()
	{
		return id;
	}
	
	public String getScreenName()
	{
		return screenName;
	}
	
	public String getSource()
	{
		return source;
	}
	
	public String getText()
	{
		return text;
	}
	
	public String getDateString()
	{
		return dateString;
	}
}
